#ifndef BORROWBOOK_H
#define BORROWBOOK_H

#include <QWidget>
#include <bookinfob.h>
#include <datastruct.h>
#include <QStandardItemModel>
#include <QSqlTableModel>
#include<QSqlRecord>
#include<QSqlError>
#include<QDebug>
#include "dboperation.h"
#include "QRoleReader.h"
#include "QMyPageWidget.h"
namespace Ui {
class BorrowBook;
}

class BorrowBook : public QMyPageWidget
{
    Q_OBJECT

public:
    explicit BorrowBook(QWidget *parent = 0);
    ~BorrowBook();

        virtual void notify();
private slots:
    void on_button_search_clicked();

    void on_button_req_clicked();

private:
    QList<Book> List_Book;
    Ui::BorrowBook *ui;
    BookInfoB* bookInfo;
    QSqlTableModel *M;
    DBOperation *db;
protected slots:
    void showBookInfo();
    void update_Book(const int &index);
};

#endif // BORROWBOOK_H
